#include "Camara.h"

Camara::Camara(){}

Camara::Camara(const Vector& p, const Vector& d, const Vector& u, const double& f) : pos(p), dir(d), up(u), fl(f) {}

Vector Camara::position() const{
	return pos;
}

Vector Camara::direction() const{
	return dir;
}

Vector Camara::upside() const{
	return up;
}

double Camara::focal_length() const{
	return fl;
}

void Camara::move(int d, const double& l){
	if(d==UP) pos = pos + up*l;
	else if(d==RIGHT) pos = pos + (dir^up).normalize()*l;
	else if(d==FW) pos = pos + dir*l;
}

